

/*
plot crisis measures

output:
- f4d_crisis_measures.pdf: combined HKM/R&R financial crisis indicators

*/


* plotting options
set scheme lean_uncluttered

********************************************************************************
********************************************************************************

* HKM data
use ../data/hkm_monthly.dta, clear
* year only format
format ym %tmCY
twoway line icr_level ym if ym>=ym(1995, 1), ///
	xtitle("") ytitle("Intermediary Capital Ratio") ///
	title("Panel A: Market-Based (He, Kelly, Manela 2016)") ///
	name("crisis_hkm", replace) 

* RR data
use ../data/rr_us_fincrisis.dta, clear
* year only format
format yh %thCY
twoway bar rr_crisis yh if yh>=yh(1995, 1), ///
	xtitle("") ytitle("Financial Crisis Indicator") ///
	title("Panel B: Narrative-Based (Romer and Romer 2017)") ///
	name("crisis_rr", replace)

* combine with correct size and export
local fname f4d_crisis_measures
* vertical layout
graph combine crisis_hkm crisis_rr, ///
	rows(2) imargin(tiny) xsize(5) ysize(8) name(`fname', replace)
graph export ../figs/`fname'.pdf, replace
graph export ../figs/`fname'.eps, replace



